var express = require('express');
var router = express.Router();
let {cartModel } = require('../model/model_dxr');

/* GET home page. */
router.get('/', function (req, res, next) {
  res.render('index', { title: 'Express' });
});

router.get('/cart',async (req,res)=>{
  let cart = await cartModel.find()
  res.send({cart})
})

module.exports = router;
